<div data-diy="place" data-diy-id="${path}">
	<header class="tab-header fs-5">
		<b class="pb-2">最新评论</b>
	</header>
<@cms.commentList pageSize=3>
	<@import path="/ftl/tools.ftl" namespace="t"/><#-- 工具 -->
	<ul class="comments-list px-0 pt-4" data-diy="comment">
		<#list page.list as a>
		<@t.merge 'userIds' a.userId!/>
		<@t.merge 'userIds' a.replyUserId!/>
		<@t.merge 'contentIds' a.contentId!/>
		</#list>
		<@sys.user ids=t.userIds!><#assign userMap=map!/></@sys.user>
		<@cms.content ids=t.contentIds!><#assign contentMap=map!/></@cms.content>
		<#list page.list as a>
		<li class="comment" data-diy-item="${a.id}">
			<div class="d-flex align-items-center">
				<figure class="rounded-circle">
					<img alt="${userMap[a.userId?string].nickname}" src="${userMap[a.userId?string].cover!(site.sitePath+'assets/img/logo-graphic.png')}">
				</figure>
				<div>
					<a href="${site.dynamicPath}member/user.html?id=${a.userId}" class="fw-bold me-2">${userMap[a.userId?string].nickname}</a><span><#if userMap[a.userId?string].superuser>[管理员]</#if></span><#if a.replyUserId?has_content><span class="text-muted ms-2">回复</span><a href="${site.dynamicPath}member/user.html?id=${a.replyUserId}" class=" fw-bold ms-2">${userMap[a.replyUserId?string].nickname}</a></#if>
					<div class="text-secondary text-opacity-50 fs-8">${a.createDate?string('yyyy-MM-dd HH:mm')}</div>
				</div>
			</div>
			<p class="mt-1">
				<a href="${contentMap[a.contentId?string].url}#comments">${a.text!}</a>
			</p>
		</li>
		</#list>
	</ul>
</@cms.commentList>
</div>
